home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1996 #14
/
Monster Media No. 14 (April 1996) (Monster Media, Inc.).ISO
/
prog_bas
/
easynet.zip
/
DEMO.ZIP
/
FLOWCHAR.FRM
< prev
next >
Wrap
Text File
|
1996-01-01
|
9KB
|
333 lines
VERSION 4.00
Begin VB.Form Form4
Appearance = 0 'Flat
BackColor = &H00FFFFFF&
Caption = "Example 4: FlowChart"
ClientHeight = 4155
ClientLeft = 1095
ClientTop = 1485
ClientWidth = 7365
DrawStyle = 5 'Transparent
BeginProperty Font
name = "MS Sans Serif"
charset = 1
weight = 700
size = 8.25
underline = 0 'False
italic = 0 'False
strikethrough = 0 'False
EndProperty
ForeColor = &H000000C0&
Height = 4560
Left = 1035
LinkTopic = "Form4"
MDIChild = -1 'True
ScaleHeight = 4155
ScaleWidth = 7365
Tag = "4"
Top = 1140
Width = 7485
Begin VB.PictureBox Picture1
Appearance = 0 'Flat
AutoSize = -1 'True
BackColor = &H80000005&
ForeColor = &H80000008&
Height = 930
Index = 3
Left = 4500
Picture = "FLOWCHAR.frx":0000
ScaleHeight = 900
ScaleWidth = 900
TabIndex = 4
Top = 3030
Visible = 0 'False
Width = 930
End
Begin VB.PictureBox Picture1
Appearance = 0 'Flat
AutoSize = -1 'True
BackColor = &H80000005&
ForeColor = &H80000008&
Height = 930
Index = 2
Left = 4500
Picture = "FLOWCHAR.frx":0802
ScaleHeight = 900
ScaleWidth = 900
TabIndex = 3
Top = 2070
Visible = 0 'False
Width = 930
End
Begin VB.PictureBox Picture1
Appearance = 0 'Flat
AutoSize = -1 'True
BackColor = &H80000005&
ForeColor = &H80000008&
Height = 930
Index = 1
Left = 4500
Picture = "FLOWCHAR.frx":1004
ScaleHeight = 900
ScaleWidth = 900
TabIndex = 2
Top = 1110
Visible = 0 'False
Width = 930
End
Begin VB.PictureBox Picture1
Appearance = 0 'Flat
AutoSize = -1 'True
BackColor = &H80000005&
ForeColor = &H80000008&
Height = 930
Index = 0
Left = 4500
Picture = "FLOWCHAR.frx":1806
ScaleHeight = 900
ScaleWidth = 900
TabIndex = 1
Top = 150
Visible = 0 'False
Width = 930
End
Begin VBX.EasyNet Net1
Alignment = 7 'Center - MIDDLE
AutoScroll = -1 'True
AutoSize = 2 'Adjust Node Size to Picture
BackColor = &H00FFFFFF&
DrawColor = &H00000000&
DrawStyle = 5 'Transparent
DrawWidth = 1
FillColor = &H00F8FCF8&
FontBold = 0 'False
FontItalic = 0 'False
FontName = "MS Sans Serif"
FontSize = 8.25
FontStrikethru = 0 'False
FontUnderline = 0 'False
ForeColor = &H000000C0&
Height = 3795
Hiding = 0 'False
ImageFile = ""
Left = 240
License = "FLOWCHAR.frx":2008
LinkHead = 7 'Empty Arrow 45
MultiSel = -1 'True
ScrollBars = 3 'Both
Shape = 1 'Rectangle
TabIndex = 0
Top = 180
Transparent = -1 'True
Version = 183
Width = 4065
xGrid = 15
yGrid = 15
End
End
Attribute VB_Name = "Form4"
Attribute VB_Creatable = False
Attribute VB_Exposed = False
Private Sub banner4()
Dim idLink2&, idLink1&
' Draw transparent except for links (see AddLink event)
Net1.DrawStyle = 5
' Create nodes
Net1.EditAction = 0
Net1.X1 = 200
Net1.Y1 = 200
Net1.ForeColor = RGB(0, 0, 0)
Net1.Text = "BEGIN"
Net1.Picture = Picture1(1).Picture
Net1.Shape = 1
Net1.Type = 1
Net1.Org = Net1.Item
Net1.EditAction = 0
Net1.X1 = 200
Net1.Y1 = 2200
Net1.Text = "STEP1"
Net1.Picture = Picture1(0).Picture
Net1.Type = 0
Net1.Dst = Net1.Item
Net1.EditAction = 1
Net1.Org = Net1.Dst
Net1.EditAction = 0
Net1.X1 = 2200
Net1.Y1 = 2200
Net1.Text = "Success?"
Net1.Picture = Picture1(2).Picture
Net1.Shape = 3
Net1.Type = 2
Net1.Dst = Net1.Item
Net1.EditAction = 1
Net1.Org = Net1.Dst
Net1.EditAction = 0
Net1.X1 = 4200
Net1.Y1 = 1000
Net1.Text = "STEP3"
Net1.Picture = Picture1(0).Picture
Net1.Type = 0
Net1.Dst = Net1.Item
Net1.EditAction = 1
Net1.PointCount = 1
Net1.PointX(0) = 2640
Net1.PointY(0) = 1440
Net1.Text = "YES"
idLink1 = Net1.Item
Net1.EditAction = 0
Net1.X1 = 4200
Net1.Y1 = 3400
Net1.Text = "STEP2"
Net1.Shape = 0
Net1.Picture = Picture1(3).Picture
Net1.Type = 3
Net1.Dst = Net1.Item
Net1.EditAction = 1
Net1.PointCount = 1
Net1.PointX(0) = 2640
Net1.PointY(0) = 3840
Net1.Text = "NO"
Net1.ForeColor = RGB(0, 255, 0)
Net1.LinkHead = 6
idLink2 = Net1.Item
Net1.EditAction = 0
Net1.X1 = 6200
Net1.Y1 = 2200
Net1.Text = "END"
Net1.ForeColor = RGB(0, 0, 0)
Net1.Picture = Picture1(1).Picture
Net1.Shape = 1
Net1.Type = 1
Net1.Dst = Net1.Item
Net1.Item = idLink1
Net1.Org = Net1.Dst
Net1.EditAction = 1
Net1.PointCount = 1
Net1.PointX(0) = 6625
Net1.PointY(0) = 1440
Net1.Item = idLink2
Net1.Org = Net1.Dst
Net1.EditAction = 1
Net1.PointCount = 1
Net1.PointX(0) = 6625
Net1.PointY(0) = 3840
Net1.LinkHead = 6
Net1.Item = 0
End Sub
Private Sub Form_Activate()
ActivateForm
End Sub
Private Sub Form_Deactivate()
DeactivateForm
End Sub
Private Sub Form_Load()
MDI1.ShowExample(3).Enabled = False
SpeedON Net1
banner4
SpeedOFF Net1
End Sub
Private Sub Form_Resize()
If WindowState <> 1 And ScaleHeight <> 0 Then
Net1.Visible = False
Net1.Top = 0
Net1.Left = 0
Net1.Height = ScaleHeight
Net1.Width = ScaleWidth
Net1.Visible = True
End If
End Sub
Private Sub Form_Unload(Cancel As Integer)
MDI1.ShowExample(3).Enabled = True
MDI1.Command5.Enabled = False
MDI1.Command5.Caption = "Comments "
End Sub
Private Sub Net1_AddLink()
Net1.DrawStyle = 6
Net1.ForeColor = RGB(0, 0, 255)
End Sub
Private Sub Net1_AddNode()
Net1.Picture = Picture1(0).Picture
End Sub
Private Sub Net1_DblClick()
If Net1.Item <> 0 Then
If Net1.IsLink = False Then
Legend = Net1.Text
Picnum = Net1.Type
AutoSize = Net1.AutoSize
AlignMent = Net1.AlignMent
frmLegend.Show 1
If Ok Then
Net1.Text = Legend
Net1.Type = Picnum
Net1.AutoSize = AutoSize
Net1.AlignMent = AlignMent
Net1.Picture = Picture1(Picnum).Picture
'Choose a shape that is near picture shape
Select Case Picnum
Case 0 ' Rectangle
Net1.Shape = 1
Case 1
Net1.Shape = 2
Case 2
Net1.Shape = 3
Case 3
Net1.Shape = 0
End Select
End If
End If
End If
End Sub
Private Sub Net1_KeyDown(KeyCode As Integer, Shift As Integer)
Dim l&
Select Case KeyCode
Case KEY_DELETE
Net1.EditAction = 2
Case KEY_LEFT
l = SendMessage(Net1.hWnd, WM_HSCROLL, SB_LINEUP, 0)
Case KEY_RIGHT
l = SendMessage(Net1.hWnd, WM_HSCROLL, SB_LINEDOWN, 0)
Case KEY_DOWN
l = SendMessage(Net1.hWnd, WM_VSCROLL, SB_LINEDOWN, 0)
Case KEY_UP
l = SendMessage(Net1.hWnd, WM_VSCROLL, SB_LINEUP, 0)
Case KEY_NEXT
l = SendMessage(Net1.hWnd, WM_VSCROLL, SB_PAGEDOWN, 0)
Case KEY_PRIOR
l = SendMessage(Net1.hWnd, WM_VSCROLL, SB_PAGEUP, 0)
End Select
End Sub
Private Sub Net1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
CursorShape Net1
End Sub